home *** CD-ROM | disk | FTP | other *** search
/ HPAVC / HPAVC CD-ROM.iso / VELENG10.ZIP / PNSEARCH.H < prev    next >
C/C++ Source or Header  |  1997-07-27  |  1KB  |  61 lines

  1. #include <time.h>
  2.  
  3. #define SEARCH_ENGINE_VERSION "V1.07"
  4.  
  5. #define MAXVALUE 200000000L
  6.  
  7. #define PROVED        1
  8. #define DISPROVED    -1
  9. #define UNKNOWN       0
  10. #define UNIMPORTANT 127
  11.  
  12. #define AND_TYPE 1
  13. #define OR_TYPE  2
  14.  
  15. #define MEM2USE (10*1024L*1024L)
  16. #define MAXNODESNUMB 40960
  17.  
  18. struct bintree {
  19.                     struct bintree *parent;
  20.                     struct bintree *lson,*rson;
  21.                     struct node *node;
  22.                     };
  23.  
  24. struct node {
  25.                 struct node *parent[7];
  26.                 struct node *child[7];
  27.                 unsigned char square[(BOARDX+1)*(BOARDY+2)];
  28.                 unsigned char stack[BOARDX+1],turn,symmetric[7];
  29.                 long proof,disproof;
  30.                 short value,expanded,type,evaluated,direct;
  31.                 };
  32.  
  33. struct dbtree {
  34.                   struct dbtree *parent;
  35.                   struct dbtree *lson,*rson;
  36.                   unsigned char cpos[12];
  37.                   short stacked;
  38.                   short value;
  39.                   };
  40.  
  41. struct small_tree {
  42.                         struct small_tree *parent,*lson,*rson;
  43.                         unsigned char buffer[14];
  44.                   };
  45.  
  46. struct parameters {
  47.                   time_t start,end;
  48.                   long maxnodes;
  49.                   long nodes,pr,ds,nodes_added;
  50.                   };
  51.  
  52. struct bintree *init_bin_tree(struct node *);
  53. struct node *check_node(struct bintree *,struct node *,short);
  54. struct dbtree *init_dbase(unsigned char *,short);
  55.  
  56. struct bintree *fast_init_bin_tree(struct node *);
  57. struct node *fast_check_node(struct bintree *,struct node *,short);
  58.  
  59.  
  60.  
  61.